@import '~@styles/common.less';

.removeArticleConfirm {
  :global {
    .ant-modal-body {
      display: flex;
      justify-content: center;
      align-items: center;
      padding: 30px 20px;
    }
    .ant-modal-confirm-body {
      display: flex;
      justify-content: center;
      align-items: center;
      flex-direction: column;

      .anticon {
        display: none;
      }
    }
    .ant-modal-confirm-btns {
      display: flex;
      justify-content: center;

      .ant-btn {
        width: 50%;
        height: 35px;
      }
    }
    .ant-modal-confirm-content {
      text-align: center;
      margin-left: 0 !important;
    }
  }
}

.darkRemoveArticleConfirm {
  :global {
    .ant-modal-body {
      background-color: @dark-bgc;
    }

    .ant-modal-confirm-body {
      .ant-modal-confirm-title,
      .ant-modal-confirm-content {
        color: @dark-fc;
      }
    }
  }
}

.overlayClassName {
  :global {
    .ant-popover-inner {
      background-color: @dark-gray;
      color: @dark-fc;
    }
    .ant-popover-inner-content {
      color: @dark-fc;
    }
    .ant-popover-arrow-content {
      --antd-arrow-background-color: @dark-gray;
    }
  }
}

.wrap {
  width: 100%;

  .item {
    flex: 1;
    height: 150px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 10px;
    margin-bottom: 1px;
    background-color: @fff;
    cursor: pointer;

    &:first-child {
      border-top-left-radius: 5px;
      border-top-right-radius: 5px;
    }

    &:nth-last-child(2) {
      border-bottom-left-radius: 5px;
      border-bottom-right-radius: 5px;
    }

    &:hover {
      .imageScaleStyle {
        transform: scale(1.5);
        transition: all 0.5s ease-in-out;
      }

      .actions {
        display: flex;
        justify-content: space-between;
        line-height: 22px;
        font-weight: normal;

        .edit {
          margin-right: 10px;
        }
      }

      .text {
        background-color: rgba(0, 0, 0, 0.35);
        transition: all 0.3s ease-in-out;
      }
    }

    .imgWrap {
      position: relative;
      display: flex;
      align-items: center;
      justify-content: center;
      width: 50%;
      max-width: 230px;
      height: 100%;
      margin-right: 20px;
      border-radius: 5px;

      .cardImgWrap {
        position: absolute;
        width: 230px;
        height: 130px;

        .mask {
          position: absolute;
          top: 0;
          left: 0;
          display: flex;
          align-items: center;
          justify-content: center;
          font-size: 16px;
          padding: 0 10px;
          width: 100%;
          height: calc(100% + 1px);
          z-index: 100;
          background-color: #fbefda;
          border: 1px solid #ffcb00;
          color: @font-danger;
          border-radius: 5px;
        }

        .image {
          width: 100%;
          min-height: 130px;
          border-radius: 5px;
          transition: all 0.5s ease-in-out;
        }
      }

      .text {
        display: flex;
        justify-content: center;
        align-items: center;
        position: relative;
        height: 100%;
        width: 100%;
        border-radius: 5px;
        z-index: 1;
        color: @fff;
        transition: all 0.3s ease-in-out;
      }
    }

    .info {
      flex: 1;
      display: flex;
      justify-content: space-between;
      flex-direction: column;
      text-align: left;
      width: 0;
      height: 100%;

      .name {
        .title {
          .ellipsis();
        }
      }

      .classifyInfo {
        font-size: 13px;
        .ellipsis();

        span {
          padding: 0 10px;
          color: @font-4;

          &:first-child {
            padding-left: 0;
          }
        }

        .tag {
          color: @menu-active;
        }

        .classify {
          border-left: 2px solid @layer-3-border;
          border-right: 2px solid @layer-3-border;
        }

        .darkClassify {
          border-left: 2px solid @dark-gray;
          border-right: 2px solid @dark-gray;
        }
      }

      .name {
        display: flex;
        justify-content: space-between;
        align-items: center;
        font-size: 16px;
        font-weight: 700;
        .ellipsis();
      }

      .desc {
        text-overflow: -o-ellipsis-lastline;
        overflow: hidden;
        text-overflow: ellipsis;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        line-clamp: 2;
        -webkit-box-orient: vertical;
      }

      .date {
        .ellipsis();
        border-left: 2px solid @layer-3-border;
      }

      .darkDate {
        border-left: 2px solid @dark-gray;
      }

      .action {
        display: flex;
        justify-content: space-between;
        align-items: center;

        .icons {
          height: 28px;
          line-height: 28px;

          .iconList {
            display: flex;
            align-items: center;
          }

          display: flex;
          justify-content: space-between;
          flex: 1;
          // width: 95%;
          margin-bottom: 0;
          .clickNoSelectText();
          .ellipsis();

          .classifyWrap {
            display: flex;
            justify-content: space-between;
            align-items: center;

            .classifyTag {
              display: inline-block;
              margin-left: 10px;
              padding: 2px 10px;
              background-color: @background;
              border-radius: 8px;
            }

            .darkClassifyTag {
              background-color: @dark-gray;
            }
          }

          .isLike {
            color: @menu-active;
            margin-bottom: 3px;
          }

          .eyes {
            font-size: 19px;
          }
        }

        .popover {
          margin-left: 10px;
        }
      }
    }
  }

  .dark {
    background-color: @dark-bgc-deep;
    color: @dark-fc;
  }

  .darkText {
    color: @font-5;
  }

  .moveIcon {
    color: @font-warning;
    font-weight: normal;
  }

  .delIcon {
    color: @danger-1-normal;
    font-weight: normal;
  }

  .skeletonWrap {
    display: flex;
    align-items: center;
    padding-top: 16px;
    height: 150px;
    padding-bottom: 0;

    .skeletonAvatar {
      height: 130px;
      width: 200px;
      margin-right: 10px;
      margin-bottom: 16px;
      border-radius: 5px;
    }
  }

  .noMore {
    text-align: center;
    padding: 12px 0 5px 0;
  }

  .darkNoMore {
    color: @dark-fc;
  }

  .actions {
    display: none;
  }
}

.btn {
  display: inline-block;
  cursor: pointer;

  &:hover {
    color: @menu-active;
  }
}

.delBtn {
  color: @danger-1-normal;
}

.edit {
  margin-right: 10px;
}

.iconMore {
  margin-right: 0;
}

.iconWrap {
  margin-right: 20px;
}

@media screen and (max-width: 960px) {
  .wrap {
    width: 100%;

    .item {
      position: relative;

      .info {
        .mobileDesc {
          display: flex;
          justify-content: space-between;
          align-items: center;
          margin: 5px 0 10px 0;

          .desc {
            text-overflow: -o-ellipsis-lastline;
            overflow: hidden;
            text-overflow: ellipsis;
            display: -webkit-box;
            -webkit-line-clamp: 3;
            line-clamp: 3;
            -webkit-box-orient: vertical;
          }

          .mobileImgWrap {
            position: relative;
            width: auto;
            height: 66px;
            margin-left: 10px;

            .mask {
              display: flex;
              justify-content: center;
              align-items: center;
              position: absolute;
              bottom: 0;
              left: 0;
              width: 100%;
              height: 100%;
              border: 1px solid @sunlight;
              font-size: 16px;
              background-color: @del-rgba;
              color: @font-danger;
              border-radius: 5px;
              z-index: 100;
            }

            .image {
              width: auto;
              height: 66px;
            }
          }
        }
      }

      .actions {
        position: relative;
        display: flex;
        line-height: 22px;
      }
    }

    .skeletonWrap {
      display: flex;
      align-items: center;
      padding-top: 15px;
      height: 150px;
      padding-bottom: 0;

      .skeletonAvatar {
        height: 70px;
        width: 118px;
        margin-left: 10px;
        margin-bottom: 16px;
        border-radius: 5px;
      }
    }

    .noMore {
      text-align: center;
      padding: 10px 0 10px 0;
    }
  }

  .iconWrap {
    margin-right: 15px;
  }
}
